﻿using System;
using System.Collections.Generic;
using System.Text;
using System.Linq;

namespace _018传值_输出_引用_数组_具名_可选参数_9__LinQ
{
    internal class Program
    {
        static void Main(string[] args)
        {
            List<int>  myList=new List<int>() { 11,12,13,14,15};
            //bool result = AllGreaterThanTen(myList);
            bool result = myList.All(item => item> 10);
            Console.WriteLine(result);
        }

        static bool AllGreaterThanTen(List<int> intlist)
        {
            foreach (var item in intlist) {
                if (item <= 10) {
                    return false;
                }
            }
            return true;
        }
    }
}
